function s = noise(signal);
  before = signal(1:end-2);
  point  = signal(2:end-1);
  after  = signal(3:end);
  s = median(abs(point - (before + after)/2));
endfunction
